<% extends 'public/base.html'%>
<% block content %>
<link rel="stylesheet" href="<< url_for('static', filename='css/detail.min.css') >>">
  <div class="main-newsdate">
    <div class="layui-container content">
      <p class="news"><a href="/news/">实时新闻</a> > 新闻详情</p>
      <h1 id="name"><< news.title >></h1>
      <p class="pushtime" id="createTime">发布时间：<span><< news.pubtime_date >> << news.pubtime_time >></span></p>
      <div class="introBott post_content" id="content">
        << news.content | safe >>
      </p>
      <blockquote class="layui-elem-quote introTop"><p><a href="<< news.href >>" target="_blank"><i class="layui-icon layui-icon-next"></i> 显示原文</a></p></blockquote>
    </div>
  </div>
    <input type="hidden" value="<< id >>" id="news_id">
  </div>
<% endblock %>
<% block script%>
    var imglist=$("#content img");
      for(var i=0;i<imglist.length;i++){
          imglist.eq(i).parent('p').css({'text-align':'center'});
          if(imglist.eq(i).attr('data-original')){
             img_url=imglist.eq(i).attr('data-original');
          }
          else{
             img_url=imglist.eq(i).attr('src');
          }
          imglist.eq(i).attr('src',img_url)
      }
<% endblock %>